import { createRouter, createWebHistory } from 'vue-router'
import DateShowing from '../views/DateShowing.vue'
import ProjectTreeShowing from '../views/ProjectTreeShowing.vue'
import TaskVisualization from '../views/ChartShowing.vue'

const router = createRouter({
  history: createWebHistory(import.meta.env.BASE_URL),
  routes: [
    {
      path: '/',
      name: 'dateshowing',
      component: DateShowing,
    },
    {
      path: '/list',
      name: 'projecttree',
      // route level code-splitting
      // this generates a separate chunk (ProjectList.[hash].js) for this route
      // which is lazy-loaded when the route is visited.
      component: ProjectTreeShowing,
    },
    {
      path: '/visualization',
      name: 'projectvisualization',
      component: TaskVisualization,
    },
  ],
})

export default router
